package com.atguigu.common;

import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder;

public class Passenter {
    public static void main(String[] args) {
        BCryptPasswordEncoder passwordEncoder = new BCryptPasswordEncoder();
        String encode = passwordEncoder.encode("admin");
//        memberEntity.setPassword(encode);
        System.out.println(encode);
        boolean admin = passwordEncoder.matches("admin", "$2a$10$xbAxEN1MPkug8uDWyqbhn.c9IwRVCAo9NLXLlcbvesT9P46KdCYWi");
        System.out.println(admin);
    }
}
